/**
 * Writed by yura and mak
 */

package wz.legend;

import java.util.HashMap;
import java.util.Map;

import wz.legend.handlers.auction.BuyingContext;
import wz.legend.handlers.farming.FarmingContext;
import wz.legend.handlers.instance.InstanceContext;
import wz.legend.util.ScriptStarter;


public class Context {
    private Status status;
    private Map<String, Object> properties = new HashMap<String, Object>();
    private ScriptStarter scriptStater;

    public synchronized Status getStatus() {
        return status;
    }

    public synchronized void setStatus(Status status) {
        this.status = status;
    }

    public synchronized ScriptStarter getScriptStater() {
        return scriptStater;
    }

    public synchronized void setScriptStater(ScriptStarter scriptStater) {
        this.scriptStater = scriptStater;
    }

    public synchronized void addProperty(String name, Object value) {
        properties.put(name, value);
    }

    public synchronized Object getProperty(String name) {
        return properties.get(name);
    }

    public synchronized Object removeProperty(String name) {
        return properties.remove(name);
    }
}
